<%@ taglib prefix="form" uri="/WEB-INF/tlds/hdiv-spring-form-3_0_4.tld"%>
<%@ taglib prefix="c" uri="/WEB-INF/tlds/hdiv-c.tld"%>
<%@ taglib uri="http://displaytag.sf.net" prefix="display"%>
<%@ taglib uri="/WEB-INF/tlds/hdiv-spring.tld" prefix="spring"%>

<c:url value="mostrarHWF4013.html" var="consistenciaAbonos"/>

<script type="text/javascript">
 $(document).ready(function(){
        $("#fechadesde").datepicker();
        $("#fechahasta").datepicker();
    });
    function abrir(){
        winwidth='450';
        winheight='920';
        $("#accion").attr("value","mostrarReporte");
        if($('#isReimpresion').attr('checked'))
            $("#formulario").attr("value","HMR4013");
        else
            $("#formulario").attr("value","HMR40131");
        window.open('about:blank', 'window1', 'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=1,width='+winwidth+',height='+winheight);
        $("form").attr("target","window1");
        $("form").submit();
    }
    function abrir2() {    
    if (document.forms[0].isReimpresion.checked == true){
            document.forms[0].formulario.value="HMR4013";
            }
        else
            {
            document.forms[0].formulario.value="HMR40131";
            }
      winwidth='450';
      winheight='920';
      window.open('about:blank', 'window1', 'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=1,width='+winwidth+',height='+winheight);   
      var accion = "mostrarReporte";
      var target = "window1";
      document.forms[0].target = target;
      document.forms[0].accion.value = accion;
      document.forms[0].submit();
      }
    
    </script>
<form:form modelAttribute="form" action="${consistenciaAbonos}">
  <form:hidden path="accion"/>
  <form:hidden path="formulario"/>
  
<!--Favoritos:-->
<input type="hidden" id="codOpci" value="${codOpci}"/>
<input type="hidden" id="desOpci" value="${desOpci}"/>

  <table id="fullheighttable" width="775" cellspacing="0" cellpadding="0"
         align="center">
    <tr>
      <td align="left" valign="top" class="padtop16left21">
        <table border="0" cellspacing="0" cellpadding="0"
               class="verdana11bazul">
          <tr>
            <td height="22" align="left" valign="top" class="verdana11bazul">
              <ul class="navlist2">
                <li>Consistencia de Abonos</li>
              </ul>
            </td>
            <td width="165"></td>
            <td>
               <a href="#" id="opener_agregarFavoritos"> <img src="images/agregar_favoritos.png" width="25" height="23" border="0" title='Agregar Favoritos'/></a>
            </td>
            
          </tr>
          <tr>
            <td align="left" valign="top" class="borde_totalblanco">
              <table border="0" cellspacing="0" cellpadding="0">
                <tr>
                  <td width="105" height="23" align="left" valign="top"
                      class="verdana10bazul">Cliente</td>
                  <td height="23" align="left" valign="top"
                      class="verdana10negro">
                    <c:out value="${sessionScope.nombreCliente}"/>
                  </td>
                </tr>
                <!-- Muestra el grupo de clientes en caso de coorporación      -->
                <c:if test="${not empty listaClientes}">
                  <tr>
                    <td width="105" height="32" align="left" valign="bottom"
                        class="verdana10bazul">
                      <spring:message code="HMF2003.grupoCliente.titulo"/>
                    </td>
                    <td width="182" height="32" align="left" valign="bottom"
                        class="verdana10negro">
                      <form:select cssStyle="height: 20px; width: 180px; font-family: Arial; font-size: 8pt"
                                   path="grupoCliente">
                        <form:option value=""></form:option>
                        <form:options items="${listaClientes}"
                                      itemValue="codCliente"
                                      itemLabel="nombre"/>
                      </form:select>
                    </td>
                  </tr>
                </c:if>
                <tr>
                  <td height="34" align="left" valign="bottom"
                      class="verdana10bazul">Fecha</td>
                  <td width="367" height="34" align="left" valign="bottom"
                      class="verdana10negro">
                    <table border="0" cellspacing="0" cellpadding="0">
                      <tr>
                        <td align="left" valign="bottom" class="padright10">
                          <div class="fondo_txtbox90">
                            <form:input maxlength="10" size="12"
                                        path="fechadesde" readonly="false"/>
                          </div>
                        </td>
                        <td class="padright10">al&nbsp;&nbsp;</td>
                        <td align="left" valign="bottom" class="padright10">
                          <div class="fondo_txtbox90">
                            <form:input maxlength="10" size="12"
                                        path="fechahasta" readonly="false"/>
                          </div>
                        </td>
                        <td>&nbsp;</td>
                      </tr>
                    </table>
                  </td>
                </tr>
                <tr>
                  <td width="105" height="34" align="left" valign="bottom"
                      class="verdana10bazul">Re impresion</td>
                  <td width="332" valign="bottom">
                    <form:checkbox path="isReimpresion" id="isReimpresion"/>
                  </td>
                </tr>
              </table>
              <table border="0" cellspacing="0" cellpadding="0" width="100%">
                <tr>
                  <td height="51" align="center" valign="bottom" width="100%">
                    <input type="button" value="Mostrar" name="reporte"
                           class="boton" onclick="abrir();"/>
                  </td>
                </tr>
              </table>
            </td>
          </tr>
        </table>
        <div class="margintop31"/>
      </td>
    </tr>
  </table>
</form:form>